@import "mixin_helpers";
@import "font-awesome-mixins";

$radius: 0px;
$border-color: #d2d2d2;
$txt-color: #666;
$select-height: 28px;

.select2-container {
  width: 100%;

  .select2-choice {
    border: 1px solid #ccc;
    @include border-radius($radius);
    @include std-bg(#fff, #f5f5f5);
  }

  &.select2-drop-above .select2-choice {
    border-bottom-color: $border-color;
    @include border-radius(0 0 $radius $radius);
    @include std-bg(#fff, #f5f5f5);
  }
}

.select2-default {
  color: #666 !important;
}

.select2-results {
  .select2-highlighted {
    background: #519FC7;
  }
}

.select2-drop {
  border: 1px solid $border-color;
  border-top: 0;
  @include border-radius(0 0 $radius $radius);
  @include box-shadow(none);
  &.select2-drop-above {
    border-top: 1px solid $border-color;
    @include box-shadow(none);
    @include border-radius($radius $radius 0 0);
  }
}

.select2-container .select2-choice {
  color: $txt-color;
  height: $select-height;
}

.select2-container .select2-choice div {
  border-left: 1px solid transparent;
  @include border-radius(0 $radius $radius 0);
  background: transparent;
  width: 20px;


  b {
    background: none;
    &:after {
      @include icon-sort-down;
      top: 2px;
      right: 2px;
      @include font-awesome-char;
    }
  }
}

.select2-search {
  &:after {
    @include icon-search;
    @include font-awesome-char;
    top: 5px;
    right: 10px;
  }
}

.select2-search input {
  border: 1px solid #ccc;
  background: #fff;

}

.select2-search input.select2-active {
  background: #fff image-url("loading.gif") no-repeat 100%;
}

.select2-container-active {
  .select2-choice, .select2-choices {
    border: 1px solid #bbb;
    @include box-shadow(none);
  }
}

.select2-dropdown-open .select2-choice {
  @include box-shadow(none);
  background: #fff;
}

//multiple choices

.select2-container-multi .select2-choices {
  background: #fff;
  border: 1px solid $border-color;
}

.select2-container-multi {
  &.select2-container-active .select2-choices {
    border: 1px solid $border-color;
    @include box-shadow(none);
  }
}

.select2-container-multi .select2-choices {
  .select2-search-choice {
    @include border-radius(2px);
    @include box-shadow(none);
    @include std-bg(#fcfcfc, #f2f2f2);
    border: 1px solid $border-color;
  }
}

.select2-container-multi .select2-search-choice-close {
  background: none;
  &:after {
    @include icon-remove;
    top: -4px;
    right: -2px;
    @include font-awesome-char;
  }
}